<?php 
$this->set("title_for_layout", $product_category['ProductCategory']['name']);
//debug($html->url("/"));    exit;
?>
<?php echo $html->css('/products/css/page/page');?>
<h2 class="title">Sản phẩm &amp; Dịch vụ</h2>
<div class="wd-right-content">
	<div class="wd-section">
		<div class="title">
            <h2 class="title_product"><?php __("Danh mục sản phẩm"); ?></h2>
        </div>            
        <ul class="news_list">
            <?php foreach($product_categories as $category){ ?>
            <?php 
                if($category['ProductCategory']['alias'] == $product_category['ProductCategory']['alias']) 
                    $class = "class='current'";
                else $class = "";                        
            ?>                
                <li <?php echo $class; ?>><a href="<?php echo $html->url('/products/products/listproducts/') . $category['ProductCategory']['alias'];?>"><span><?php echo $category['ProductCategory']['name']; ?></span></a></li>
            <?php } ?>
        </ul>
	</div>
</div>
<div class="wd-main-content">
	<div class="wd-section">
		<div class="sub_section">
			<h3 class="sub_title"><a href="<?php echo $html->url(array('plugin' => 'products', 'controller' => 'products', 'action' => 'listproducts', $product_category['ProductCategory']['alias'])); ?>"><?php echo $product_category['ProductCategory']['name'] ?></a></h3>
			<ul class="product_block">
            <?php foreach($products as $product): ?>
				<li>
					<a class="link" href="<?php echo $html->url('/products/products/view/') . $product['Product']['alias']. "/" . "thiet-bi-giam-sat";?>">
                        <?php echo $html->image('/files/products/'. $html->getThumbnailName($product['Product']['image']), array("class" => "img_product"));?>
						<span><?php echo $product['Product']['title']; ?></span>
					</a>
				</li>
            <?php endforeach; ?>
			</ul>
		</div>
        <?php echo $this->element('pagination/pagination', array('model' => 'Product'));?>
	</div>	
</div>